<template>
  <div class="about">
    <h1>This is an about page</h1>
     <pagination v-show="total >0" :total="total" :page.sync="listQuery.page" :limit.sync="listQuery.limit" @pagination="getList"></pagination>
  </div>
</template>
<script>
import Pagination from '@/components/Pagination'
export default {
  components: { Pagination },
  data(){
    return{
      total:0,
      listQuery:{
        page:1,
        limit:5,
        title:''
      },
    }
  },
  created(){
    this.getList()
  },
  methods:{
    getList(){  //获取整个table数据的接口
      /**
       * fetch(this.listQuery).then((res)=>{
       *  this.total = res.data.totle
       * })
       */

      this.listQuery.page = 1
      this.listQuery.limit = 5
      this.total = 20
    },
  }
}
</script>
